From: Jonas Ã…dahl Date: Wed, 17 Aug 2022 14:32:52 +0000 (+0200) Subject: main: Tear down the gjs context before the mutter context X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~405^2^2~233 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=1559f03a82317e06aa0596bf12feb8b761a58f52;p=gnome-shell.git main: Tear down the gjs context before the mutter context Tearing down gjs means that we won't have any dangling references kept alive by GC or otherwise alive Javascript objects, when we finally tear down the mutter context. This allows for a clean shutdown of GNOME Shell. Part-of: --- diff --git a/src/main.c b/src/main.c index 468e58849..269fe56c9 100644 --- a/src/main.c +++ b/src/main.c @@ -587,14 +587,14 @@ main (int argc, char **argv) g_message ("Shutting down GNOME Shell"); _shell_global_notify_shutdown (shell_global_get ()); - - meta_context_destroy (g_steal_pointer (&context)); - shell_profiler_shutdown (); - g_debug ("Doing final cleanup"); + g_debug ("Tearing down the gjs context"); _shell_global_destroy_gjs_context (shell_global_get ()); g_object_unref (shell_global_get ()); + g_debug ("Tearing down the mutter context"); + meta_context_destroy (g_steal_pointer (&context)); + return ecode; }